home *** CD-ROM | disk | FTP | other *** search
/ Monster Media 1996 #15 / Monster Media Number 15 (Monster Media)(July 1996).ISO / utils / ffind230.zip / DELTRASH.BAT < prev    next >
DOS Batch File  |  1996-01-10  |  1KB  |  24 lines

  1. @echo off
  2. if "%tmp%"=="" if "%temp%"=="" echo Please set 'tmp' environment variable (this can't be done from NC&clones!)
  3. if "%tmp%"=="" if "%temp%"=="" goto end
  4. if "%tmp%"=="" if not "%temp%"=="" set tmp=%temp%
  5. set f=%tmp%\notrash!.bat
  6. del %f% >NUL
  7. call mtrash.bat rem ------------------------ Temporary files, safe to delete
  8. ffind *:*.$$$ *.swp *.tmp [%comspec% /c mtrash.bat del %%FULLPATH]
  9. call mtrash.bat rem ------------------------ Backup files, sometimes usefull
  10. ffind *:*.bak *.*~* [%comspec% /c mtrash.bat del %%FULLPATH]
  11. call mtrash.bat rem ------------------------ List, map files from compilers, think before deleting
  12. ffind *:*.lst *.obj *.map [%comspec% /c mtrash.bat del %%FULLPATH]
  13. call mtrash.bat rem ------------------------ User specified files (if any)
  14. if "%1"=="" goto :cont
  15. ffind *:%1 %2 %3 %4 %5 %6 %7 %8 %9 [%comspec% /c mtrash.bat del %%FULLPATH]
  16. type %f% | find "\do\not\delete\here" /v > %f%
  17. :cont
  18. echo Do you have your favourite editor named ed? (^C if not)
  19. call ed %f%
  20. echo Do you *really* want to delete that files (^C if not)
  21. pause
  22. call %f%
  23. :end
  24.